1. Field of the Invention
The present invention pertains to computerized three dimensional geometric modeling systems, and particularly to a three dimensional geometric modeling system which permits a combination of differing data structure/modeling representation types to be utilized for representing solid shapes comprising a part or scene.
2. Related Art and Other Considerations
The computer has greatly affected essentially all forms of information management, including the geometric modeling arts. Nowadays there are numerous computer program products that allow the user to create, store, and modify geometric models and their graphical renderings of various types on a display screen, and to print or otherwise output such geometric models and their renderings. Such geometric models and their graphical renderings span the gambit from simple to complex, and can vary in subject matter, e.g., artistic, industrial, etc. Some geometric modeling computer program products are two dimensional, providing only length and width dimensions of objects. The more complex three dimensional computer program products, on the other hand, provide three dimensionsxe2x80x94length, width, and depth/thickness.
Three dimensional geometric modeling programs can generate a scene or part which can comprise one or more constituent 3D solid shapes. For example, a scene featuring a simple table would comprise a solid shape for each leg of the table, as well as a solid shape for a flat table top. The geometric modeling computer program typically has an executable object used to define and generate each solid shape. The object for each solid shape can have several components, the components being a combination of executable code and data structure. For example, a boundary representation (xe2x80x9cB-repxe2x80x9d) component includes a data structure describing the geometry and topology data for the solid shape (e.g., length, width, depth, and coordinates of the solid part).
Most three dimensional geometric modeling programs employ a feature-based parametric modeling technique. In feature-based parametric modeling, the executable object for each solid shape has not only a boundary representation component, but also a history or creation component which includes a data structure reflecting how a solid shape has been created. That is, the history/creation component includes data which indicates an order or chronological sequence of steps employed to construct the solid shape. For a simple solid block, for example, the history/creation component may indicate that the solid block began as a simple two dimensional rectangle that was extruded into a third dimension. U.S. patent application Ser. No. 08/635,293, filed Apr. 19, 1996, entitled xe2x80x9cIntelligent Shapes For Authoring Three-Dimensional Modelsxe2x80x9d, incorporated herein by reference, discloses solid shapes having various other components in addition to boundary representation and historical components: a visual component; a physical component; a functional component; and a behavioral component.
Solid parts can be formed from other solid parts. This happens often, for example, in an assembly drawing comprised of one or more sub-assemblies and solid parts. In geometric modeling terms, the building of more complicated solid shapes in hierarchical fashion from simpler solid shapes (known as xe2x80x9cprimitivesxe2x80x9d) is known as xe2x80x9cconstructed solid geometryxe2x80x9d (xe2x80x9cCSGxe2x80x9d). The simpler solid shapes can be combined using various operations (e.g., Boolean operations such as xe2x80x9candxe2x80x9d, xe2x80x9corxe2x80x9d, xe2x80x9cnotxe2x80x9d, etc.). The computer stores the overall (complex) solid shape as a tree, each of the xe2x80x9cleavesxe2x80x9d of the tree comprising a primitive solid shape.
Typically, when the user wants to modify a feature-based solid shape by changing any aspect of the solid shape, the feature-based parametric modeling technique re-evaluates the entire solid shape, e.g., goes through the entire CGS history tree in order to revise the part in accordance with the change. For example, if the user wanted to lengthen the table top of the table described above, another solid shape would be added adjacent to the previous table top. In so adding another solid shape corresponding to the increased length of the table top, another step is added to the CSG history. Alternatively, the user may modify the 2D profile of the table top and let the program to re-evaluate the solid shape of the table.
Thus, modifying solid shapes using feature-based parametric modeling can be inefficient. Moreover, in some instances a modification attempted by a user in a feature-based parametric modeling may provide a result different than that expected by the user.
An alternate approach to feature-based parametric modeling is known as direct face modeling. The direct face parametric modeling technique allows for face editing of a solid shape or feature. For example, in the table illustration provided above, the user can simply click and pull on the table top, resulting in an elongation of the table top. Such a modification in the direct face parametric modeling does not result in re-evaluation of the entire solid shape. In fact, in direct face parametric modeling there is no historical information associated with a solid shape. That is, a direct face-modeled solid shape does not include any history or creation information.
What is needed, and an object of the present invention, is a three dimensional computer aided geometric modeling system which combines desirable aspects of both feature-based parametric modeling and direct face parametric modeling techniques.
A computer program product and system executing/implementing the same provides a visual depiction of a three dimensional object upon a display device. The program initially uses a feature-based data structure for plural solid shapes comprising the three dimensional object. Besides providing traditional feature-based modeling capabilities, when input from the user input device designates a designated solid shape, the computer program product creates a direct face data structure (D-Shape) for the designated solid shape. The user input can take the form of a command that the designated solid shape be converted from a feature-based data structure to a direct face data structure, or movement of a face or surface in a manner requiring direct face modeling. The program converts the feature-based data structure of the D-Shape to a direct face data structure in a manner to keep a history of the three dimensional object consistent with a resulting boundary representation component of the three dimensional object.
In converting the feature-based data structure of the designated solid shape to the direct face data structure, the program (1) determines what other solid shapes should be included in the D-Shape; (2) generates a boundary representation for the D-Shape; (3) uses a topology-changeable local operation to generate a modified boundary representation for the D-Shape; (4) modifies the history of the three dimensional object; (5) includes the modified boundary representation for the D-Shape with the data structure for the solid shape; and (6) updates at least part of a history of the three dimensional object.
In determining if the direct face data structure should also encompass any solid shapes, the program considers whether any of the following should be combined in the direct face data structure: (1) adjacent solid shapes which are adjacent the designated solid shape; (2) depending solid shapes that are included in a definitional component of any other solid shape that is to be converted to a direct face data structure; (3) space overlapping solid shapes that have a spatial overlap with the designated solid shape and have conflicting order requirements.
Further, the program product and methods of the invention can construct/reconstruct a feature-based data structure from a direct face data structure (D-Shape) or from user-selected faces. The faces to be included in a new feature-based data structure can be manually selected by the user by clicking seriatim on the faces, or by using an auto-select feature. In the auto-select feature, the reconstruction process grows a selected face until a recognizable boundary is encountered. The recognizable boundary can be any one of a blend, direct face solid shape, extruded shape, or turn shape.
Once a type of selected shape has been determined from the selection, the construction/reconstruction process of the invention removes the selected faces from a boundary representation component of the D-Shape, and thereafter heals the boundary representation component of the D-Shape. A boundary representation component is then prepared for the removed faces, and an executable objected is created to include the newly prepared boundary representation component. The history of compound solid shape in which the newly created solid shape is to be included is modified, and the newly created feature-based solid shape is included in the CSG tree of the compound solid shape. The CSG tree can then be re-evaluated for display of the compound solid shape including the newly feature-based converted/reconverted solid shape.